home *** CD-ROM | disk | FTP | other *** search
Text File | 1996-05-21 | 1.1 KB | 42 lines | [TEXT/ttxt] |
- -- <<<-
-
- module CheeseTest1 uses ScriptX end
- in module CheeseTest1
-
- function sayCheese x y ->
- print "The best North American cheese comes from Wisconsin"
-
- class Cheese ()
- instance methods
- method frommage self x ->
- print "The best European cheese comes from France"
- end
-
- object myCheese (Cheese) end
-
- addTimeCallback theCalendarClock sayCheese undefined \
- undefined (theCalendarClock.time + 5) true
- addTimeCallback theCalendarClock frommage myCheese \
- undefined (theCalendarClock.time + 5) true
-
-
-
-
- addTimeCallback theCalendarClock sayCheese undefined \
- undefined (theCalendarClock.time + 30) true
- addTimeCallback theCalendarClock frommage myCheese \
- undefined (theCalendarClock.time + 30) true
-
- function sayCheese x y ->
- print "The best North American cheese comes from Ontario"
- method frommage self {class Cheese} x ->
- print "The best European cheese comes from Denmark"
-
-
-
- addTimeCallback theCalendarClock (a b -> sayCheese a b) undefined \
- undefined (theCalendarClock.time + 30) true
- function sayCheese x y ->
- print "The best North American cheese still comes from Wisconsin"
- -- >>>
-